module.exports = (app) => {
  const { STRING, INTEGER, DATE } = app.Sequelize;

  const Download = app.model.define(
    "download",
    {
      id: {
        type: INTEGER,
        primaryKey: true,
        allowNull: false,
        autoIncrement: true,
      },
      updateAt: {
        type: DATE,
        allowNull: false,
      },
      title: {
        type: STRING(255),
        allowNull: false,
      },
      link: {
        type: STRING(255),
        allowNull: false,
      },
    },
    {
      timestamps: false,
      underscored: false,
    }
  );

  return Download;
};
